<?php



class CustomersMapBuilder {

	
	const CLASS_NAME = 'lib.model.map.CustomersMapBuilder';

	
	private $dbMap;

	
	public function isBuilt()
	{
		return ($this->dbMap !== null);
	}

	
	public function getDatabaseMap()
	{
		return $this->dbMap;
	}

	
	public function doBuild()
	{
		$this->dbMap = Propel::getDatabaseMap('propel');

		$tMap = $this->dbMap->addTable('customers');
		$tMap->setPhpName('Customers');

		$tMap->setUseIdGenerator(true);

		$tMap->addPrimaryKey('CUSTOMERS_ID', 'CustomersId', 'int', CreoleTypes::INTEGER, true, null);

		$tMap->addColumn('CUSTOMERS_GENDER', 'CustomersGender', 'string', CreoleTypes::CHAR, true, 1);

		$tMap->addColumn('CUSTOMERS_FIRSTNAME', 'CustomersFirstname', 'string', CreoleTypes::VARCHAR, true, 32);

		$tMap->addColumn('CUSTOMERS_LASTNAME', 'CustomersLastname', 'string', CreoleTypes::VARCHAR, true, 32);

		$tMap->addColumn('CUSTOMERS_DOB', 'CustomersDob', 'int', CreoleTypes::DATE, true, null);

		$tMap->addColumn('CUSTOMERS_EMAIL_ADDRESS', 'CustomersEmailAddress', 'string', CreoleTypes::VARCHAR, true, 96);

		$tMap->addForeignKey('CUSTOMERS_DEFAULT_ADDRESS_ID', 'CustomersDefaultAddressId', 'int', CreoleTypes::INTEGER, 'address_book', 'ADDRESS_BOOK_ID', false, null);

		$tMap->addColumn('CUSTOMERS_TELEPHONE', 'CustomersTelephone', 'string', CreoleTypes::VARCHAR, true, 32);

		$tMap->addColumn('CUSTOMERS_FAX', 'CustomersFax', 'string', CreoleTypes::VARCHAR, false, 32);

		$tMap->addColumn('CUSTOMERS_PASSWORD', 'CustomersPassword', 'string', CreoleTypes::VARCHAR, true, 40);

		$tMap->addColumn('CUSTOMERS_NEWSLETTER', 'CustomersNewsletter', 'string', CreoleTypes::CHAR, false, 1);

	} 
} 